package lschgcdev.apis;
import java.util.*;

public class DataUser<V> extends Settings
{
	public TreeMap<String, V> dataMap = new TreeMap<String, V>();
	
	public DataUser(){
		super();
	}
	
	public DataUser(String UID){
		super(UID);
	}
	
	public void putData(String key, V value){
		dataMap.put(key, value);
	}
	
	@SuppressWarnings("unchecked")
	public <T> T getData(String key){
		return (T)dataMap.get(key);
	}
	
	@SuppressWarnings("unchecked")
	public <T> T getData(Class<T> cast, String key){
		return (T)dataMap.get(key);
	}
	
}
